home *** CD-ROM | disk | FTP | other *** search
/ Champak 138 / Volume 138 Aug 19 2011 - Damaged.iso / Games / tobby_on_ice.swf / scripts / DefineSprite_105_ice / frame_1 / DoAction.as
Text File  |  2011-08-19  |  993b  |  54 lines

  1. function main()
  2. {
  3.    if(_root.pauseFlg)
  4.    {
  5.       return undefined;
  6.    }
  7.    this.stream();
  8. }
  9. function stream()
  10. {
  11.    var _loc1_ = this;
  12.    var _loc2_ = _root;
  13.    if(_loc2_.bgMC._x >= 0)
  14.    {
  15.       _loc1_.px += _loc1_.pdx + _loc2_.hoseidx;
  16.    }
  17.    else
  18.    {
  19.       _loc1_.px += _loc1_.pdx - _loc2_.scrolldx + _loc2_.hoseidx;
  20.    }
  21.    if(_loc1_.px < -150)
  22.    {
  23.       _loc1_.px = _loc1_.resetLocX - 150;
  24.       if(_loc1_.iceSize == 5)
  25.       {
  26.          if(_loc2_.stat == "main")
  27.          {
  28.             _loc2_.tobbyMC.setMissFromJelly();
  29.          }
  30.       }
  31.    }
  32. }
  33. function reset()
  34. {
  35.    if(this.iceSize == 4)
  36.    {
  37.       this.objMC.bullJrMC.reset();
  38.    }
  39. }
  40. this.px = this._x;
  41. this.py = this._y;
  42. _root.scrolldx = 0;
  43. if(_root.stageNum == 3)
  44. {
  45.    _root.totalBonusCnt += this.iceSize;
  46.    nIDname = "ice" + String(this.iceSize) + "g";
  47.    this.goldMCList = [];
  48. }
  49. else
  50. {
  51.    var nIDname = "ice" + String(this.iceSize);
  52. }
  53. this.attachMovie(nIDname,"objMC",0);
  54.